package com.tem.content.bean;

import com.tem.common.tool.result.ResultEnum;
import com.tem.common.tool.result.ResultUtil;
import lombok.Data;

import java.io.Serializable;

/**
 * 提返回值封装
 * @author 腾木科技 Created by 2021/11/25 11:09
 */
@Data
public class Cms1ResultUtil<T> extends ResultUtil implements Serializable {

    private static final long serialVersionUID = -116823410481453759L;

    /**
     * 响应状态码
     */
    private Integer statusCode;

    /**
     * 消息提示
     */
    private String errMsg;

    public static <T> Cms1ResultUtil<T> successMy(T data) {
        Cms1ResultUtil resultUtil = new Cms1ResultUtil();
        resultUtil.setStatusCode(200);
        resultUtil.setErrMsg("request:ok");
        resultUtil.setData(data);
        return resultUtil;
    }
}
